<div class="primary">
    <div class="main-content">
        <div class="main-content-left">
            <div class="breadcrumb">
            	<span itemtype="http://data-vocabulary.org/Breadcrumb" itemscope="itemscope" class="crumb_item">
            		<a itemprop="url" rel="up" class="crumb" href="<?=DOMAIN?>/"><span itemprop="title">Trang chủ</span></a>
            		<span class="arrow"><img src="<?=$path_images_page?>navRow.png" alt="bredcrumb arrow"/></span>
            	</span>
            	<span itemtype="http://data-vocabulary.org/Breadcrumb" itemscope="itemscope" class="crumb_item">
            		<a itemprop="url" rel="up" class="crumb" href="<?=DOMAIN?>/<?=removeTitle($list_news[0]['cat_name'])?>.htm"><span itemprop="title"><?=$list_news[0]['cat_name']?></span></a>
            	</span>
                <span class="breadcrumb_date"><?=getDateTime('','1','1','0','',time())?></span>
            </div>
            <h1 style="width:0px; height:0px; overflow:hidden;text-indent:-9999em;">Tin tức <?=$list_news[0]['cat_name']?> cập nhật</h1>
        <?php
        foreach($list_news as $news) {
            ?>
            <div class="cat-news-box">
                <div class="cat-new-box-left">
                    <div class="img">
                        <a href="<?=generate_detail_url($news)?>"><img alt="<?=$news['new_title']?>" src="<?=$news['new_picture']?>" /></a>
                    </div>
                    <div class="cont">
                        <a href="<?=generate_detail_url($news)?>"><h2><?=$news['new_title']?></h2></a>
                        <p><?=$news['new_teaser'] != '' ? cut_string(removeHTML($news['new_teaser']),200,'.') : cut_string(removeHTML($news['new_detail']),300)?></p>
                    </div>
                </div><!-- End cat-news-box-left -->
                <div class="cat-new-box-right"> 
                    <ul>
                    <?php
                    $relate = news_relate($news,3);                
                    for($i = 0; $i < 3; $i++) {
                        if(isset($relate[$i])) {
                            ?>
                            <li><a href="<?=generate_detail_url($relate[$i]);?>"><h3><?=$relate[$i]['new_title']?></h3></a></li>
                            <?
                        }
                    }
                    ?>
                    </ul>
                </div><!-- End cat-news-box-right -->
            </div><!-- End cat-news-box -->
            <?
        }
        ?>
            <div class="paging">
                <?php if($page > 1 && isset($list_news[0]['cat_name'])):?>
                <a href="<?=generate_cat_page_url($list_news[0]['cat_name'],$page-1)?>">[Trang trước]</a>
                <a href="<?=generate_cat_page_url($list_news[0]['cat_name'],$page+1)?>">[Trang sau]</a>
                <?php elseif($page > 1 && !isset($list_news[0]['cat_name'])):?>
                <p>Hết tin trong mục này !</p>
                <?php else:?>
                <a href="<?=generate_cat_page_url($list_news[0]['cat_name'],$page+1)?>">[Trang sau]</a>
                <?php endif;?>
            </div>
        </div><!-- End main-content-left -->
        <div class="main-content-right">
            <img alt="quang cao" src="../themes/img/adv2.jpg" />
        </div><!-- End main-content-right -->
    </div><!-- End main-content -->
</div><!-- End primary -->